<?php
/*
 * @category   Epic
 * @package    Epic
 * @author     Epic Core Team <rukanhitokiri@gmail.com>
 */
class Epic_Debug
{
	/**
	 * Format dump data
	 * 
	 * @param mix $var
	 */
    public static function dump($var)
    {
        // var_dump the variable into a buffer and keep the output
        ob_start();
        var_dump($var);
        $output = ob_get_clean();

        // neaten the newlines and indents
        $output = preg_replace("/\]\=\>\n(\s+)/m", "] => ", $output);
        $output = '<pre>'
                . $output
                . '</pre>';
   		echo($output);
    }

}
